home *** CD-ROM | disk | FTP | other *** search
-
-
-
- AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM)))) AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM))))
-
-
-
- NNNNAAAAMMMMEEEE
- automount - automatically mount NFS filesystems
-
- SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
- ////uuuussssrrrr////eeeettttcccc////aaaauuuuttttoooommmmoooouuuunnnntttt [ ----mmmmnnnnTTTTvvvv ] [ ----DDDD _n_a_m_e=_v_a_l_u_e ] [ ----ffff _m_a_s_t_e_r-_f_i_l_e ] [ ----pppp
- _p_r_i_o_r_i_t_y ] [ ----MMMM _m_o_u_n_t-_d_i_r_e_c_t_o_r_y ] [ ----ttttllll _d_u_r_a_t_i_o_n ] [ ----ttttmmmm _i_n_t_e_r_v_a_l ] [ ----ttttpppp
- _d_u_r_a_t_i_o_n ] [ ----ttttwwww _i_n_t_e_r_v_a_l ] [ _d_i_r_e_c_t_o_r_y _m_a_p_n_a_m_e [ -_m_o_u_n_t-_o_p_t_i_o_n_s ] ] ...
-
- DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
- _A_u_t_o_m_o_u_n_t is a daemon that automatically and transparently mounts NFS
- filesystems as needed. Whenever a user on a client machine running
- _a_u_t_o_m_o_u_n_t invokes a command that needs to access a remote file or
- directory, the hierarchy to which that file or directory belongs is
- mounted and remains mounted for as long as it is needed. When a certain
- amount of time has elapsed during which the hierarchy is not accessed, it
- is automatically unmounted. No mounting of unaccessed remote filesystems
- is done at boot-time, and the user doesn't need special privilege to
- mount a directory.
-
- The _a_u_t_o_m_o_u_n_t daemon is started during system initialization from the
- /_e_t_c/_i_n_i_t._d/_n_e_t_w_o_r_k script if the configuration flags ``nfs'' and
- ``automount'' are set ``on.'' Do the following commands as super-user to
- enable _a_u_t_o_m_o_u_n_t:
-
- /etc/chkconfig nfs on
- /etc/chkconfig automount on
-
- Rebooting will start _a_u_t_o_m_o_u_n_t with the options and arguments contained
- in the file /_e_t_c/_c_o_n_f_i_g/_a_u_t_o_m_o_u_n_t._o_p_t_i_o_n_s. The default version of this
- file lets you access exported directories on another host with the
- filename prefix of
-
- /hosts/<_h_o_s_t_n_a_m_e>/
-
-
- For example, if host _s_p_r_i_n_g_f_i_e_l_d exports /_u_s_r, then
-
- ls /hosts/springfield/usr
-
- will show the contents of that directory. You may want to customize this
- file for your site.
-
- Unlike _m_o_u_n_t, _a_u_t_o_m_o_u_n_t does not consult the file /_e_t_c/_f_s_t_a_b for a list
- of hierarchies to mount. Rather, it consults a series of maps, which can
- be either direct or indirect. The names of the maps can be passed to
- _a_u_t_o_m_o_u_n_t from the command line (via the /_e_t_c/_c_o_n_f_i_g/_a_u_t_o_m_o_u_n_t._o_p_t_i_o_n_s
- file), or from another (_m_a_s_t_e_r) map.
-
- The master map lists (as if from the command line) all other maps,
- applicable options, and mount points.
-
-
-
-
-
- PPPPaaaaggggeeee 1111
-
-
-
-
-
-
- AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM)))) AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM))))
-
-
-
- An indirect map allows you to specify mappings for the subdirectories you
- wish to mount under the _d_i_r_e_c_t_o_r_y indicated on the command line. In an
- indirect map, each _d_i_r_e_c_t_o_r_y field consists of the basename of a
- subdirectory to be mounted as needed.
-
- A direct map contains mappings for any number of directories. Each
- directory listed in the map is automatically mounted as needed. The
- direct map as a whole is not associated with any single directory.
-
- _a_u_t_o_m_o_u_n_t appears to be an NFS server to the kernel. _a_u_t_o_m_o_u_n_t uses the
- map contained in the _m_a_p_n_a_m_e argument to locate an appropriate NFS file
- server, exported filesystem, and mount options. It then mounts the
- filesystem in a temporary location, and creates a symbolic link to the
- temporary location. If the filesystem is not accessed within an
- appropriate interval (five minutes by default), the daemon unmounts the
- filesystem and removes the symbolic link. If the indicated directory has
- not already been created, the daemon creates it, and then removes it upon
- exiting.
-
- By default, _a_u_t_o_m_o_u_n_t mounts everything under the directory /_t_m_p__m_n_t.
- For instance, if a user wants to mount a remote directory _s_r_c under
- /_u_s_r/_s_r_c, the actual mount point will be /_t_m_p__m_n_t/_u_s_r/_s_r_c, and /_u_s_r/_s_r_c
- will be a symbolic link to that location.
-
- As with any other kind of mount, a mount effected through the automounter
- on a non-empty mount point will hide the original contents of the mount
- point for as long as the mount is in effect.
-
- Since the name-to-location binding is dynamic, updates to an _a_u_t_o_m_o_u_n_t
- map are transparent to the user. This obviates the need to ``pre-mount''
- shared file systems for applications that have ``hard-coded'' references
- to files. Nor is there a need to maintain records of which hosts must be
- mounted for what applications.
-
- If the _d_i_r_e_c_t_o_r_y argument is a pathname, the _m_a_p argument points to an
- _i_n_d_i_r_e_c_t map. An indirect map contains a list of the subdirectories
- contained within the indicated _d_i_r_e_c_t_o_r_y. With an indirect map, it is
- these subdirectories that are mounted automatically.
-
- If the _d_i_r_e_c_t_o_r_y argument is `/-', _a_u_t_o_m_o_u_n_t treats the _m_a_p argument that
- follows as the name of a _d_i_r_e_c_t map. In a direct map, each entry
- associates the full pathname of a mount point with a remote filesystem to
- mount.
-
- A map can be a file or a network information service (NIS) map; if a
- file, the _m_a_p argument must be a full pathname.
-
- The -_m_o_u_n_t-_o_p_t_i_o_n_s argument, when supplied, consists of the leading dash
- and a comma-separated list of options to _m_o_u_n_t(1M), as described in
- _f_s_t_a_b(4). If these options are supplied, they become the default mount
- options for all entries in the map. Mount options provided within a map
- entry override these defaults.
-
-
-
- PPPPaaaaggggeeee 2222
-
-
-
-
-
-
- AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM)))) AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM))))
-
-
-
- OOOOPPPPTTTTIIIIOOOONNNNSSSS
- ----DDDD _v_a_r=_v_a_l_u_e
- Assign _v_a_l_u_e to the indicated automount (environment) variable.
-
- ----ffff _m_a_s_t_e_r-_f_i_l_e
- Read a local file for initialization, before reading the _a_u_t_o._m_a_s_t_e_r
- NIS map. The information in _m_a_s_t_e_r-_f_i_l_e will take precedence.
-
- ----mmmm Suppress initialization of _d_i_r_e_c_t_o_r_y-_m_a_p_n_a_m_e pairs listed in the
- _a_u_t_o._m_a_s_t_e_r NIS database.
-
- ----MMMM _m_o_u_n_t-_d_i_r_e_c_t_o_r_y
- Mount temporary filesystems in the named directory, instead of
- /_t_m_p__m_n_t.
-
- ----nnnn Disable dynamic mounts. With this option, references through the
- _a_u_t_o_m_o_u_n_t daemon only succeed when the target filesystem has been
- previously mounted. This can be used to prevent NFS servers from
- cross-mounting each other.
-
- ----TTTT Trace. Expand each NFS call and display it on standard error.
-
- ----pppp _p_r_i_o_r_i_t_y
- Set the (non-degrading) priority of the automount process. The
- default is NDPNORMAX (40).
-
- ----ttttllll _d_u_r_a_t_i_o_n
- Specify a _d_u_r_a_t_i_o_n, in seconds, that a filesystem is to remain
- mounted when not in use. The default is 300 seconds (5 minutes).
-
- ----ttttmmmm _i_n_t_e_r_v_a_l
- Specify an _i_n_t_e_r_v_a_l, in seconds, between attempts to mount a
- filesystem. The default is 30 seconds.
-
- ----ttttpppp _d_u_r_a_t_i_o_n
- Specify the _d_u_r_a_t_i_o_n, in seconds, that the results of a probe of a
- server's availability will remain cached. The default is 5 seconds.
-
- ----ttttwwww _i_n_t_e_r_v_a_l
- Specify an _i_n_t_e_r_v_a_l, in seconds, between attempts to unmount
- filesystems that have exceeded their cached times. The default is
- 60 seconds.
-
- ----vvvv Verbose. Log status and/or warning messages through _s_y_s_l_o_g(3B) or
- to the console.
-
- EEEENNNNVVVVIIIIRRRROOOONNNNMMMMEEEENNNNTTTT
- Environment variables can be used within an automount map. For instance,
- if $HOME appeared within a map, _a_u_t_o_m_o_u_n_t would expand it to its current
- value for the HOME variable. Environment variables are expanded only for
- the automounter's environment - not for the environment of a user using
- the automounter's services.
-
-
-
- PPPPaaaaggggeeee 3333
-
-
-
-
-
-
- AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM)))) AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM))))
-
-
-
- If a variable reference needs to be protected from affixed characters,
- you can surround the variable name with curly braces.
-
- UUUUSSSSAAAAGGGGEEEE
- MMMMaaaapppp EEEEnnnnttttrrrryyyy FFFFoooorrrrmmmmaaaatttt
- A simple map entry (mapping) takes the form:
-
- _d_i_r_e_c_t_o_r_y [ ----_m_o_u_n_t-_o_p_t_i_o_n_s ] _l_o_c_a_t_i_o_n ...
-
- where _d_i_r_e_c_t_o_r_y is the full pathname of the directory to mount when used
- in a direct map, or the basename of a subdirectory in an indirect map.
- _m_o_u_n_t-_o_p_t_i_o_n_s is a comma-separated list of options to _m_o_u_n_t(1M), as
- described in _f_s_t_a_b(4), and _l_o_c_a_t_i_o_n specifies a remote filesystem from
- which the directory may be mounted. In the simple case, _l_o_c_a_t_i_o_n takes
- the form:
-
- _h_o_s_t_n_a_m_e:_p_a_t_h_n_a_m_e
-
- _R_e_p_l_i_c_a_t_e_d _F_i_l_e_s_y_s_t_e_m_s
- Multiple _l_o_c_a_t_i_o_n fields can be specified for replicated read-only
- filesystems, in which case _a_u_t_o_m_o_u_n_t sends multiple mount requests;
- _a_u_t_o_m_o_u_n_t mounts the filesystem from the first host that replies to the
- mount request. This request is first made to the local net or subnet.
- If there is no response, any connected server may respond. Since
- _a_u_t_o_m_o_u_n_t does not monitor the status of the server while the filesystem
- is mounted, it will not use another location in the list if the currently
- mounted server crashes. This support for replicated filesystems is
- available only at mount time. Once unmounted, another location may be
- used for subsequent mounts of the filesystem.
-
- If each _l_o_c_a_t_i_o_n in the list shares the same _p_a_t_h_n_a_m_e then a single
- _l_o_c_a_t_i_o_n may be used with a comma-separated list of hostnames:
-
- _h_o_s_t_n_a_m_e_1,_h_o_s_t_n_a_m_e_2:_p_a_t_h_n_a_m_e
-
- _S_h_a_r_i_n_g _M_o_u_n_t_s
- If _l_o_c_a_t_i_o_n is specified in the form:
-
- _h_o_s_t_n_a_m_e:_p_a_t_h_n_a_m_e:_s_u_b_d_i_r
-
- _h_o_s_t_n_a_m_e is the name of the server from which to mount the filesystem,
- _p_a_t_h_n_a_m_e is the pathname of the directory to mount, and _s_u_b_d_i_r, when
- supplied, is the name of a subdirectory to which the symbolic link is
- made. This can be used to prevent duplicate mounts when multiple
- directories in the same remote filesystem may be accessed. With an
- indirect map for /_h_o_m_e such as:
-
- bart springfield:/home/simpsons:bart
- maggie springfield:/home/simpsons:maggie
-
- and a user attempting to access a file in /_h_o_m_e/_b_a_r_t, _a_u_t_o_m_o_u_n_t mounts
- _s_p_r_i_n_g_f_i_e_l_d:/_h_o_m_e/_s_i_m_p_s_o_n_s, but creates a symbolic link called /_h_o_m_e/_b_a_r_t
-
-
-
- PPPPaaaaggggeeee 4444
-
-
-
-
-
-
- AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM)))) AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM))))
-
-
-
- to the _b_a_r_t subdirectory in the temporarily-mounted filesystem. If a
- user immediately tries to access a file in /_h_o_m_e/_m_a_g_g_i_e, _a_u_t_o_m_o_u_n_t needs
- only to create a symbolic link that points to the _m_a_g_g_i_e subdirectory;
- /_h_o_m_e/_s_i_m_p_s_o_n_s is already mounted.
-
- With the following map:
-
- bart springfield:/home/simpsons/bart
- maggie springfield:/home/simpsons/maggie
-
-
- _a_u_t_o_m_o_u_n_t would have to mount the filesystem twice.
-
- _C_o_m_m_e_n_t_s _a_n_d _Q_u_o_t_i_n_g
- A mapping can be continued across input lines by escaping the NEWLINE
- with a backslash. Comments begin with a # and end at the subsequent
- NEWLINE.
-
- Characters that have special significance to the automount map parser may
- be protected either with double quotes (") or by escaping with a
- backslash (\). Pathnames with embedded whitespace, colons (:) or dollars
- ($) should be protected.
-
- _D_i_r_e_c_t_o_r_y _P_a_t_t_e_r_n _M_a_t_c_h_i_n_g
- The `&' character is expanded to the value of the _d_i_r_e_c_t_o_r_y field for the
- entry in which it occurs. In this case:
-
- bart springfield:/home/simpsons:&
-
- the & expands to _b_a_r_t. The `*' character, when supplied as the _d_i_r_e_c_t_o_r_y
- field, is recognized as the catch-all entry. Such an entry will be used
- if any previous entry has not successfully matched the key being searched
- for. For instance, if the following entry appeared in the indirect map
- for /_h_o_m_e:
-
- * &:/home/&
-
- this would allow automatic mounts in /_h_o_m_e of any remote filesystem whose
- location could be specified as:
-
- _h_o_s_t_n_a_m_e:/_h_o_m_e/_h_o_s_t_n_a_m_e
-
- _M_u_l_t_i_p_l_e _M_o_u_n_t_s
- A multiple mount entry takes the form:
-
- _d_i_r_e_c_t_o_r_y [ /[ _s_u_b_d_i_r_e_c_t_o_r_y [ ----_m_o_u_n_t-_o_p_t_i_o_n_s ] _l_o_c_a_t_i_o_n ... ] ...
-
- The initial / preceding the _s_u_b_d_i_r_e_c_t_o_r_y is required; the optional
- _s_u_b_d_i_r_e_c_t_o_r_y is taken as a pathname relative to the _d_i_r_e_c_t_o_r_y. If
- _s_u_b_d_i_r_e_c_t_o_r_y is omitted in the first occurrence, the / refers to the
- directory itself.
-
-
-
-
- PPPPaaaaggggeeee 5555
-
-
-
-
-
-
- AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM)))) AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM))))
-
-
-
- Given the direct map entry:
-
- /tools \
- / -ro dill:/tools mint:/tools \
- /1.0 -ro mint:/tools/1.0 dill:/tools/1.0 \
- /1.0/man -ro dill:/tools/1.0/man mint:/tools/1.0/man
-
- _a_u_t_o_m_o_u_n_t would automatically mount /_t_o_o_l_s, /_t_o_o_l_s/_1._0 and
- /_t_o_o_l_s/_1._0/_m_a_n, as needed, from either _d_i_l_l or _m_i_n_t, whichever host
- responded first. If the mounts are hierarchically related, mounts closer
- to the root must appear before submounts. All the mounts of a multiple
- mount entry will occur together and will be unmounted together. This is
- important if the filesystems reference each other with relative symbolic
- links. Multiple mount entries can be used both in direct maps and in
- indirect maps.
-
- IIIInnnncccclllluuuuddddeeeedddd MMMMaaaappppssss
- The contents of another map can be included within a map with an entry of
- the form:
-
- +_m_a_p_n_a_m_e
-
- _m_a_p_n_a_m_e can either be a filename, or the name of an NIS map, or one of
- the special maps described below. If the directory being searched for is
- not located in an included map, the search continues with the next entry.
-
- SSSSppppeeeecccciiiiaaaallll MMMMaaaappppssss
- There are two special maps currently available: -_h_o_s_t_s and -_n_u_l_l. The
- -_h_o_s_t_s map uses the NIS _h_o_s_t_s._b_y_n_a_m_e map to locate a remote host when the
- hostname is specified. This map specifies mounts of all exported
- filesystems from any host. For instance, if the following _a_u_t_o_m_o_u_n_t
- command is already in effect:
-
- automount /hosts -hosts
-
- then a reference to /_h_o_s_t_s/_s_p_r_i_n_g_f_i_e_l_d/_u_s_r would initiate an automatic
- mount of all filesystems from _s_p_r_i_n_g_f_i_e_l_d that _a_u_t_o_m_o_u_n_t can mount;
- references to a directory under /_h_o_s_t_s/_s_p_r_i_n_g_f_i_e_l_d will refer to the
- corresponding directory relative to _s_p_r_i_n_g_f_i_e_l_d's root.
-
- The -_n_u_l_l map, when indicated on the command line, cancels any subsequent
- map for the directory indicated. It can be used to cancel a map given in
- _a_u_t_o._m_a_s_t_e_r or for a mount point specified as an entry in a direct map.
-
- CCCCoooonnnnffffiiiigggguuuurrrraaaattttiiiioooonnnn aaaannnndddd tttthhhheeee aaaauuuuttttoooo....mmmmaaaasssstttteeeerrrr MMMMaaaapppp
- _a_u_t_o_m_o_u_n_t normally consults the _a_u_t_o._m_a_s_t_e_r NIS configuration map for a
- list of initial automount maps, and sets up automatic mounts for them in
- addition to those given on the command line. If there are duplications,
- the command-line arguments take precedence over a local ----ffff master map and
- they both take precedence over an NIS _a_u_t_o._m_a_s_t_e_r map. This
- configuration database contains arguments to the automount command,
- rather than mappings; unless ----ffff is in effect, _a_u_t_o_m_o_u_n_t does _n_o_t look for
-
-
-
- PPPPaaaaggggeeee 6666
-
-
-
-
-
-
- AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM)))) AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM))))
-
-
-
- an _a_u_t_o._m_a_s_t_e_r file on the local host.
-
- Maps given on the command line, or those given in a local _a_u_t_o._m_a_s_t_e_r
- file specified with ----ffff override those in the NIS _a_u_t_o._m_a_s_t_e_r map. For
- instance, given the command:
-
- automount -f /etc/auto.master /home -null /- /etc/auto.direct
-
- and a file named /_e_t_c/_a_u_t_o._m_a_s_t_e_r that contains:
-
- /homes auto.home
-
- _a_u_t_o_m_o_u_n_t would mount home directories under /_h_o_m_e_s instead of /_h_o_m_e, in
- addition to the various directories specified in the /_e_t_c/_a_u_t_o._d_i_r_e_c_t
- file.
-
- FFFFIIIILLLLEEEESSSS
- /tmp_mnt
- directory under which filesystems are dynamically mounted
-
- /etc/config/automount.options
- site-dependent options and arguments
-
- SSSSEEEEEEEE AAAALLLLSSSSOOOO
- mount(1M), network(1M), chkconfig(1M), fstab(4), exports(4), schedctl(2)
-
- NNNNOOOOTTTTEEEESSSS
- The -_h_o_s_t_s map mounts all of the exported filesystems, for which the
- client has access, from a server. Use of the _n_o_h_i_d_e export option on the
- server (see exports(4)) may be used to minimize the number of mounts
- performed by clients. Automount will not request a separate mount for a
- _n_o_h_i_d_e filesystem, if the client has access via the parent filesystem.
- If frequent access to just a single filesystem is required, it is more
- efficient to access the filesystem with a map entry that is tailored to
- mount just the filesystem of interest.
-
- When it receives signal number 1, SIGHUP, _a_u_t_o_m_o_u_n_t rereads the /_e_t_c/_m_t_a_b
- file to update its internal record of currently-mounted filesystems. If
- a filesystem mounted with _a_u_t_o_m_o_u_n_t is unmounted with the _u_m_o_u_n_t(1M)
- command, _a_u_t_o_m_o_u_n_t should be forced to reread the file by using the
- command
-
- /etc/killall -HUP automount
-
- An _l_s(1) listing of the entries in the directory for an indirect map
- shows only the symbolic links for currently mounted filesystems. This
- restriction is intended to avoid unnecessary mounts as a side effect of
- programs that read the directory and _s_t_a_t(2) each of the names.
-
- Mount points for a single automounter must not be hierarchically related.
- _a_u_t_o_m_o_u_n_t will not allow an automount mount point to be created within an
- automounted filesystem.
-
-
-
- PPPPaaaaggggeeee 7777
-
-
-
-
-
-
- AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM)))) AAAAUUUUTTTTOOOOMMMMOOOOUUUUNNNNTTTT((((1111MMMM))))
-
-
-
- The recommended way to terminate automount services is to send a SIGTERM
- signal to the daemon:
-
- /etc/killall -TERM automount
-
- This allows the automounter to catch the signal and unmount not only its
- daemon but also any mounts in /_t_m_p__m_n_t. Mounts in /_t_m_p__m_n_t that are busy
- will not be unmounted. _a_u_t_o_m_o_u_n_t must not be terminated with the SIGKILL
- signal. Without an opportunity to unmount itself, the automount mount
- points will appear to the kernel to belong to a non-responding NFS
- server.
-
- Since each direct map entry results in a separate mount for the mount
- daemon, such maps should be kept short. Although both direct and
- indirect maps can be modified at any time, entries added to a direct map
- will have no effect until the automounter is restarted.
-
- Automount mount points are mounted with type _i_g_n_o_r_e; they do not appear
- in the output of either _m_o_u_n_t(1M) or _d_f(1). Automatically-mounted
- filesystems, on the other hand, are mounted with type _n_f_s and are
- reported along with other NFS-mounted filesystems.
-
- BBBBUUUUGGGGSSSS
- Shell filename expansion does not apply to objects not currently mounted.
-
- The _b_g mount option is not recognized by the automounter.
-
- Since _a_u_t_o_m_o_u_n_t is single-threaded, any request that is delayed by a slow
- or non-responding NFS server will delay all subsequent automatic mount
- requests until it completes.
-
- Programs that read /_e_t_c/_m_t_a_b and then touch files that reside under
- automatic mount points will introduce further entries to the file.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- PPPPaaaaggggeeee 8888
-
-
-
-